package com.sskj.spk;

import android.support.multidex.MultiDexApplication;

import com.alibaba.android.arouter.facade.annotation.Autowired;
import com.alibaba.android.arouter.launcher.ARouter;
import com.sskj.common.router.service.CommonService;
import com.sskj.lib.router.service.LibService;
import com.sskj.spk.ui.activity.MainActivity;
import com.tencent.bugly.Bugly;
import com.tencent.bugly.crashreport.CrashReport;
import com.zxy.recovery.core.Recovery;

/**
 * 作者 :吕志豪
 * 简书：https://www.jianshu.com/u/6e525b929aac
 * github：https://github.com/lvzhihao100
 * 描述：
 * 创建时间：2018-10-18 08:52
 */
public class BaseApplication extends MultiDexApplication {
    @Autowired
    CommonService commonService;
    @Autowired
    LibService libService;
    public static MainActivity mainActivity;

    @Override
    public void onCreate() {
        super.onCreate();
        ARouter.openLog();
        ARouter.openDebug();
        ARouter.init(this);
        ARouter.getInstance().inject(this);
//        Recovery.getInstance()
//                .debug(true)
//                .recoverInBackground(false)
//                .recoverStack(true)
//                .mainPage(MainActivity.class)
//                .recoverEnabled(true)
//                .callback(null)
//                .silent(false, Recovery.SilentMode.RECOVER_ACTIVITY_STACK)
//                .init(this);
        CrashReport.initCrashReport(getApplicationContext(), "cfa870e543", true);


    }
}
